package com.yby6.system.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.yby6.system.domain.SysLog;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * ClassName: Loginfo
 * Description: 杨不易网站 :www.yangbuyi.top
 * date: 2021/5/12
 *
 * @author TeouBle
 * @author yangbuyi
 * @since JDK 1.8
 **/

public interface SysLogMapper extends BaseMapper<SysLog> {
	/**
	 * delete by primary key
	 *
	 * @param logId primaryKey
	 * @return deleteCount
	 */
	int deleteByPrimaryKey(Long logId);

	/**
	 * insert record to table
	 *
	 * @param record the record
	 * @return insert count
	 */
	int insert(SysLog record);

	/**
	 * select by primary key
	 *
	 * @param logId primary key
	 * @return object by primary key
	 */
	SysLog selectByPrimaryKey(Long logId);

	/**
	 * 循环批量删除
	 *
	 * @param id
	 * @return
	 */
	int deleteById(@Param("id") Long[] id);

	/**
	 * 根据条件查询列表信息
	 * @param sysLog
	 * @return
	 */
	List<SysLog> getLogByPage(SysLog sysLog);

	/**
	 * 清空全部日志
	 * @return
	 */
	int deleteAll ();

}